package com.youbug.system.controller;


import com.baomidou.mybatisplus.core.metadata.IPage;
import com.youbug.system.entity.LoginLog;
import com.youbug.system.service.ILoginLogService;
import com.youbug.system.vo.LoginLogVo;
import com.youbug.common.vo.R;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

/**
 * <p>
 * 监控前端控制器
 * </p>
 *
 * @author youbug
 * @since 2023-05-06
 */
@RestController
@RequestMapping("/loginLog")
public class LoginLogController {

    @Autowired
    private ILoginLogService loginLogService;

    @PostMapping("/getLoginLogs")
    public R<IPage<LoginLog>> getLoginLogs(@RequestBody LoginLogVo vo){

        IPage<LoginLog> page = loginLogService.getLoginLogPage(vo);

        return R.ok(page);
    }
}

